#ifndef MESSAGESYSTEM_H_
#define MESSAGESYSTEM_H_

#include "SLList.h"
#include "Messages.h"

enum EStaticImages { IMAGE_MONEYBAG, IMAGE_CASTLE1, IMAGE_CASTLE2, IMAGE_CASTLE3, IMAGE_HAND, IMAGE_ROCK, IMAGE_BUTTON, IMAGE_KOFFING, IMAGE_POT, IMAGE_BALLISTA, IMAGE_BOW, IMAGE_ARROW, IMAGE_PLAYER_ARROW, IMAGE_BOULDER,
					 IMAGE_WALNUT, IMAGE_WALNUT2, IMAGE_WALNUT3, IMAGE_PARTICLEPIC, IMAGE_PIXEL, IMAGE_SHADOW, IMAGE_SPILL, IMAGE_SPLAT, IMAGE_BALLISTA_ARROW, MAXSTATICIMAGES };

class MessageSystem
{
	SLList<CBaseMessage*> messageQueue;

	int staticImages[MAXSTATICIMAGES];

	MessageSystem() {}
	~MessageSystem() {}
	MessageSystem(const MessageSystem&);
	MessageSystem& operator =(const MessageSystem&);

public:

	static MessageSystem* GetInstance();

	void Init();
	void Shutdown();

	//int GetWalnutID()	{return staticImages[IMAGE_WALNUT];}

	int GetStaticImageID(int image)	{return staticImages[image];}

	int GetNumberMessages() { return messageQueue.size(); }
	void SendNewMessage(CBaseMessage* message);
	void ClearMessages();
	void ProcessMessages();
	void MessageProc(CBaseMessage* message);

};

#endif